package com.pro.common.service.sitecontent.model.db;

import com.pro.common.api.CommonConst;
import com.pro.common.api.enums.EnumSysRole;
import com.pro.common.api.model.BaseConfigModel;
import com.pro.common.api.model.auth.IAdminClass;
import com.pro.framework.api.enums.IEnumToDbDbId;
import com.pro.framework.javatodb.annotation.JTDField;
import com.pro.framework.javatodb.annotation.JTDTable;
import com.pro.framework.javatodb.constant.JTDConst;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

@Data
@EqualsAndHashCode(callSuper = true)
@Schema(description = "角色")
@JTDTable(sequences = {
}, module = CommonConst.Modules.siteContent)
public class AuthRole extends BaseConfigModel implements IEnumToDbDbId, IAdminClass {
    @Schema(description = "系统角色")
    private EnumSysRole sysRole;
    @Schema(description = "超级管理员")
    private Boolean superFlag;
    //    @Schema(description = "类型")
//    private String type;
    @Schema(description = "角色名称")
    private String roleName;
    @Schema(description = "关联的菜单路由")
    @JTDField(entityClass = AuthRoute.class, javaTypeEnumClassMultiple = true, type = JTDConst.EnumFieldType.text, entityClassLabel = "routeName")
    private String routeCodes;
    @Schema(description = "启用")
    private Boolean enabled;
}
